# Copyright 2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

DESCRIPTION="Package mask for MiniGentoo installation"
HOMEPAGE=""
SRC_URI=""

LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"

DEPEND=""
RDEPEND="${DEPEND}"
BDEPEND=""

pkg_preinst() {
	MINIGENTOO_PORTDIR=$(portageq get_repo_path ${PORTAGE_CONFIGROOT} minigentoo)
	MINIGENTOO_PORTAGE_DIR="${MINIGENTOO_PORTDIR}/${CATEGORY}/${PN}/files"

	elog "Installing minigentoo.mask used in this overlay"
	dosym "${MINIGENTOO_PORTAGE_DIR}/minigentoo.mask" "${PORTAGE_CONFIGROOT%/}/etc/portage/package.mask/minigentoo.mask"
	}
